<extend name="Public/base_group_mobile" />
<block name="head">
        <link rel="stylesheet" href="__GROUPM__/css/global.css?__inline">
        <link rel="stylesheet" href="__GROUPM__/css/index.css?__inline">
        <script type="x/template" id="modal-template">
        <div class="modal-mask" v-show="show" transition="modal">
            <div class="modal-wrapper">
                <div class="modal-container">
                    <div class="modal-header">
                        <slot name="header">
                        </slot>
                    </div>

                    <div class="modal-body">
                        <slot name="body">
                        </slot>
                    </div>

                    <div class="modal-footer">
                        <slot name="footer">
                        </slot>
                    </div>
                </div>
            </div>
        </div>
        </script>
</block>
<block name="header">
        <!-- 登陆弹出层 -->
        <modal :show.sync="showModal"  style="display:none;">
            <div slot="header">
                <a v-on:click="close_modal" class="btn-close">关闭</a>
            </div>

            <div slot="body">
                <div class="row row-1">
                    <input maxlength="11" value=""  id="j-ipt-mobile" type="tel" name="" value="" placeholder="手机号">
                </div>
                <p class="tip">*请输入手机号</p>
                <div class="row row-2">
                    <input autocomplete="off" maxlength="6" id="j-ipt-code" type="tel" name="" value="" placeholder="验证码">
                    <button disabled class="btn-getcode btn-disabled" id="j-btn-getcode">获取验证码</button>
                </div>
                <p class="tip">*请输入验证码</p>
                <div class="row row-3">
                    <button id="j-btn-submit" class="submit">点击登陆</button>
                </div>
            </div>
        </modal>
        <!-- /登陆弹出层 -->
        <!-- 页面加载后 -->
        <div  v-show="1 < load" style="display: none;" class="container">
            <!-- 头部 -->
            <div class="g-hd">
                <div class="bar">
                    <a class="btn-return" id='j-back'></a>
                    <img class="brand" width="140" src="__GROUPM__/img/logo.png?__inline">
                    
                    <a 
                    	<neq name="UID" value="0" >
                    		href="{:U('Customer/order')}"
                    	<else/>
                    		v-on:click="show_modal"
                    	</neq>
                    	class="btn-ucenter">
                    </a>
                </div>
        		<include file="Public/menu" />
            </div>
            <!-- /头部 -->
</block>
<block name="content">          
            <!-- 主体 -->
            <div class="g-bd">
                <div class="banner">
                    <img width="100%" src="__GROUPM__/img/banner.jpg?__inline">
                </div>
                <h1 class="title">本期团购产品</h1>

                <ul class="list" id="j-list">
                    <li transition="expand" stagger="300" v-for="goods in goods_list" class="item flex-box">
                        <a class="item-img" v-bind:href="goods.goods_link">
                           <img width="100%" v-bind:data-echo="goods.goods_thumb">
                        </a>
                        <div class="item-body">
                            <h3><a v-bind:href="goods.goods_link" v-text="goods.goods_name"></a></h3>
                            <p class="join-num">已有<a v-text="goods.group_count"></a>人参团</p>
                            <div class="price">
                                <a class="now">
                                    <span class="icon">¥</span>
                                    <span class="num" v-text="goods.shop_group_price"></span>
                                </a>
                                <a class="before">
                                    <span class="icon">¥</span>
                                    <span class="num" v-text="goods.market_price"></span>
                                </a>
                            </div> 
                        </div>
                    </li>
                </ul>

                <!-- 底部提示 -->
                <div class="u-loader">
                    <p v-if="is_end"  align="center" class="bottom-text">没有更多宝贝了^_^</p> 
                    <p  v-else align="center">
                        <img src="__GROUPM__/img/svg-loaders/three-dots.svg">
                    </p>                           
                </div>
                <!-- /底部提示 -->

            </div>
            <!-- /主体 -->
</block>
<block name="footer">            
            <!-- 回到顶部 -->
            <a id="scrollUp">TOP</a>
            <!-- 回到顶部 -->
        </div>
        <!-- 页面加载后 -->
        
        <!-- 页面加载前: loader -->
        <div v-show="1 == load" class="g-loader">
            <img  width="100%" src="__GROUPM__/img/svg-loaders/three-dots.svg">
        </div>
        <!-- /页面加载前: loader -->

		<script type="text/javascript">
//       var API_LIST = '__GROUPM__/mock/index_list.json';
			var API_LIST = "{:U('Shop/goodsGroupList')}";
			var INDEX_URL = "{:U('Shop/goodsGroup')}";
			var IS_LOGIN = "{:is_login()}";//马胜杰修改～ 
			var API_SMS = "{:U('Customer/getSms')}";
	        var API_LOGIN = "{:U('Customer/login')}";
			
	        var _hmt = _hmt || [];
	        (function() {
	            var hm = document.createElement("script");
	            hm.src = "//hm.baidu.com/hm.js?27cc4f321a7a3fb9aac51636c4157eab";
	            var s = document.getElementsByTagName("script")[0];
	            s.parentNode.insertBefore(hm, s);
	        })();
	    </script>
        <!--SCRIPT_PLACEHOLDER-->
        <script src="__STATIC__/zepto.min.js"></script>
        <script src="__STATIC__/echo-master/dist/echo.min.js"></script>
        <script src="__STATIC__/vue.js"></script>
        <script src="__GROUPM__/js/global.js"></script>
        <script src="__GROUPM__/js/index.js?__inline"></script><!--ignore-->
</block>